home *** CD-ROM | disk | FTP | other *** search
/ Amiga Developer CD 2.1 / Amiga Developer CD v2.1.iso / NDK / NDK_3.5 / Tutorials / Printer / English / Preferences.doc < prev   
Encoding:
Text File  |  1999-10-27  |  1.9 KB  |  48 lines

  1.  
  2. printer.device V44 (OS 3.5)
  3.  
  4. Preferences
  5.  
  6. The V44 printer.device supports 10 units. Each unit has its own set of
  7. preferences associated with it. These are saved as follows:
  8.  
  9. The file ENV:Sys/printer.prefs contains all settings for unit 0. The file
  10. ENV:Sys/printergfx.prefs has become obsolete. Any changes to this file are
  11. still handled by IPrefs but are always overwritten by printer.prefs if this
  12. file contains a FORM ID_PGFX.
  13.  
  14. The units 1 to 9 use the files ENV:Sys/printerN.prefs, where N is replaced
  15. by the numbers 1 to 9.
  16.  
  17. Typically the files will containg the following FORMs:
  18.  
  19. ID_PRHD: struct PrefHeader containing version and type and flags all 0.
  20.  
  21. ID_PTXT: struct PrinterTxtPrefs containing the general printer settings
  22.          and settings for text printing.
  23.  
  24. ID_PUNT: struct PrinterUnitPrefs containing the name and unit number of the device
  25.          for printer output (parallel.device or serial.device, etc.).
  26.  
  27. ID_PDEV: struct PrinterDeviceUnitPrefs containing unit number and symbolic name
  28.          for the unit of the printer.device. The name can be assigned by the
  29.          user and provides more comfort when choosing units via the
  30.          user interface.
  31.  
  32. ID_PGFX: struct PrinterGfxPrefs containing the settings for graphics printing.
  33.  
  34.  
  35. Changes to the preferences
  36.  
  37. Only the SYS:Prefs/Printer program is allowed to make changes to the preferences
  38. files and change their structure in the process. If another application wants
  39. to change the settings (e.g. the printer driver, many fax programs do this),
  40. it must preserve the structure of the file. This can be achieved by either
  41. reading all FORMs consecutively and writing them in the same order, or by reading
  42. the entire file into memory without dissolving its structure - it can the
  43. be changed and written back.
  44.  
  45. The preferences files contain no CATs or LISTs, linearly reading all
  46. FORMs and writing back all FORMs in the old order is therefore possible
  47. and permitted.
  48.